package practice;

public class arrSum01 {
    public static void main(String[] args) {
        sequenceSum();
    }
    public static void sequenceSum() {
        float x = 1;
        float y = 2;
        float t;
        float num;
        float sum = 0;
        for(int i = 1;i <= 20;i++){
            num = y / x;
            sum += num;
            t = y;
            y += x;
            x = t;
        }
        System.out.println(sum);
    }
}
